<!DOCTYPE html>

<html lang="en">
  <head>
    
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>返回响应（Returning Responses） &mdash; Phalcon 3.0.1 文档</title>
    <meta name="keywords" content="php, phalcon, phalcon php, php framework, faster php framework">
    <link rel="stylesheet" type="text/css" href="http://cdn.staticfile.org/twitter-bootstrap/3.3.6/css/bootstrap.min.css" />
    <link rel="stylesheet" type="text/css" href="/www/css/phalcon.min.css" />
    <link href='//fonts.googleapis.com/css?family=Open+Sans:700,400' rel='stylesheet' type='text/css'>
    <link href="//fonts.googleapis.com/css?family=Merriweather:400,700" rel="stylesheet" type="text/css" />
    <!--
    EUROPE <link href='//fonts.googleapis.com/css?family=Open+Sans:700,400&subset=latin-ext' rel='stylesheet' type='text/css'>
    GREEK <link href='//fonts.googleapis.com/css?family=Open+Sans:700,400&subset=greek-ext' rel='stylesheet' type='text/css'>
    RUSSIA <link href='//fonts.googleapis.com/css?family=Open+Sans:700,400&subset=cyrillic-ext,latin' rel='stylesheet' type='text/css'>
    -->

    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->

    <link rel="stylesheet" href="../static/pygments.css" type="text/css" />
    <link rel="stylesheet" href="../static/docs.css" type="text/css" />
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../',
        VERSION:     '3.0.1',
        COLLAPSE_MODINDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>

    <script src="http://cdn.staticfile.org/jquery/1.8.1/jquery.min.js"></script>
    <script type="text/javascript" src="../static/docs.js"></script>
    <link rel="shortcut icon" href="../static/favicon.ico"/>
    <link rel="top" title="Phalcon 3.0.1 文档" href="../index.html" />
    <link rel="next" title="Cookie 管理（Cookies Management）" href="cookies.html" />
    <link rel="prev" title="Request Environment" href="request.html" /> 
  </head>
  <body>

<header class="page-header">
    <nav class="navbar" role="navigation">
        <div class="container">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#main-menu-container">
                    <span class="sr-only">Toggle navigation</span><span class="icon-bar"></span><span class="icon-bar"></span><span class="icon-bar"></span>
                </button>
                <a class="navbar-brand phalcon-logo" href="/"><span itemprop="name" class="sr-only">Phalcon PHP</span></a>
            </div>

            <div class="collapse navbar-collapse navbar-right" id="main-menu-container">
                <ul class="nav navbar-nav main-menu">
                  <li class="first"><a href="//phalconphp.com/en/download" class="header-nav-link">Download</a></li>
                  <li><a href="//docs.phalconphp.com/en/latest/index.html" class="header-nav-link" target="_blank">Documentation</a></li>
                  <li><a href="//forum.phalconphp.com/" class="header-nav-link" target="_blank">Forum</a></li>
                  <li><a href="//blog.phalconphp.com/" class="header-nav-link" target="_blank">Blog</a></li>
                  <li><a href="//phalconist.com/" class="header-nav-link" target="_blank">Resources</a></li>
                  <li><a href="//phalconphp.com/en/about">About</a></li>
                  <li><div align="right">
                      <iframe src="https://ghbtns.com/github-btn.html?user=phalcon&amp;repo=cphalcon&amp;type=watch&amp;count=true&amp;size=large"
      allowtransparency="true" frameborder="0" scrolling="0" width="152px" height="30px"></iframe>
                    </div></li>
                </ul>
            </div>
        </div>
    </nav>
  </header>

<div class="heading">
    <div class="container">
        <div class="row">
            <h2>Documentation</h2>
        </div>
    </div>
</div>
    <div class="related">
      <ul>
        <li class="right" >
          <a href="../genindex.html" title="总目录"
             accesskey="I">索引</a></li>
        <li class="right" >
          <a href="cookies.html" title="Cookie 管理（Cookies Management）"
             accesskey="N">下一页</a> |</li>
        <li class="right" >
          <a href="request.html" title="Request Environment"
             accesskey="P">上一页</a> |</li>
        <li><a href="//phalconphp.com">Home</a> &raquo;</li>
        <li><a href="../index.html">Phalcon 3.0.1 文档</a> &raquo;</li> 
      </ul>
    </div>  

      <table width="100%" align="center" cellpadding="0" cellspacing="0">
        <tr>
      <td class="primary-box" width="25%" valign="top">
            <div>
            <div id="searchbox" style="">
                <!--<form class="search" action="http://readthedocs.org/search/project/" method="get">
                  <input type="search" name="q" size="25" placeholder="Search">
                  <input type="submit" value="Go">
                  <input type="hidden" name="selected_facets" value="project:">
                </form>-->
                <div style="width:200px;padding:10px">
                  <gcse:searchbox-only></gcse:searchbox-only>
                </div>
            </div>
            </div>
            <div style="padding:5px;padding-left:10px">
              <div id="carbonads-container">
                <div class="carbonad"><div id="azcarbon"></div>
                <script async type="text/javascript" src="//cdn.carbonads.com/carbon.js?zoneid=1673&serve=C6AILKT&placement=phalconphpcom" id="_carbonads_js"></script>
                </div></div>
            </div>
            <h3><a href="../index.html">內容目录</a></h3>
            <ul>
<li><a class="reference internal" href="#">返回响应（Returning Responses）</a><ul>
<li><a class="reference internal" href="#working-with-headers">使用头部信息（Working with Headers）</a></li>
<li><a class="reference internal" href="#making-redirections">重定向（Making Redirections）</a></li>
<li><a class="reference internal" href="#http-http-cache">HTTP 缓存（HTTP Cache）</a><ul>
<li><a class="reference internal" href="#setting-an-expiration-time">设置过期时间（Setting an Expiration Time）</a></li>
<li><a class="reference internal" href="#cache-control">Cache-Control</a></li>
<li><a class="reference internal" href="#e-tag">E-Tag</a></li>
</ul>
</li>
</ul>
</li>
</ul>

            <h4>上一个主题</h4>
            <p class="topless"><a href="request.html" title="上一章">&lt; Request Environment</a></p>
            <h4>下一个主题</h4>
            <p class="topless"><a href="cookies.html" title="下一章">Cookie 管理（Cookies Management） &gt;</a></p>
            <h3>本页</h3>
            <ul class="this-page-menu">
              <li><a href="../sources/reference/response.md" rel="nofollow">显示源代码</a></li>
            </ul>
        </td>
          <td class="second-box" valign="top">
            <div class="document">
                <div class="documentwrapper">
                  <div class="bodywrapper">
                    <div class="body" >
                      
  <div class="section" id="returning-responses">
<h1>返回响应（Returning Responses）<a class="headerlink" href="#returning-responses" title="永久链接至标题">¶</a></h1>
<p><a class="reference internal" href="../api/Phalcon_Http_Response.html"><em>Phalcon\Http\Response</em></a> 是Phalcon中用来处理HTTP响应返回的组件。
HTTP响应通常是由响应头和响应体组成的。下面是一些基本用法:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="k">use</span> <span class="nx">Phalcon\Http\Response</span><span class="p">;</span>

<span class="c1">// 获取一个响应实例</span>
<span class="nv">$response</span> <span class="o">=</span> <span class="k">new</span> <span class="nx">Response</span><span class="p">();</span>

<span class="c1">// 设置HTTP状态码</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setStatusCode</span><span class="p">(</span><span class="mi">404</span><span class="p">,</span> <span class="s2">&quot;Not Found&quot;</span><span class="p">);</span>

<span class="c1">// 设置响应内容</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setContent</span><span class="p">(</span><span class="s2">&quot;Sorry, the page doesn&#39;t exist&quot;</span><span class="p">);</span>

<span class="c1">// 返回响应到客户端</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">send</span><span class="p">();</span>
</pre></div>
</div>
<p>If you are using the full MVC stack there is no need to create responses manually. However, if you need to return a response
directly from a controller&#8217;s action follow this example:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="k">use</span> <span class="nx">Phalcon\Http\Response</span><span class="p">;</span>
<span class="k">use</span> <span class="nx">Phalcon\Mvc\Controller</span><span class="p">;</span>

<span class="k">class</span> <span class="nc">FeedController</span> <span class="k">extends</span> <span class="nx">Controller</span>
<span class="p">{</span>
    <span class="k">public</span> <span class="k">function</span> <span class="nf">getAction</span><span class="p">()</span>
    <span class="p">{</span>
        <span class="c1">// Getting a response instance</span>
        <span class="nv">$response</span> <span class="o">=</span> <span class="k">new</span> <span class="nx">Response</span><span class="p">();</span>

        <span class="nv">$feed</span> <span class="o">=</span> <span class="c1">// ... Load here the feed</span>

        <span class="c1">// Set the content of the response</span>
        <span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setContent</span><span class="p">(</span>
            <span class="nv">$feed</span><span class="o">-&gt;</span><span class="na">asString</span><span class="p">()</span>
        <span class="p">);</span>

        <span class="c1">// Return the response</span>
        <span class="k">return</span> <span class="nv">$response</span><span class="p">;</span>
    <span class="p">}</span>
<span class="p">}</span>
</pre></div>
</div>
<div class="section" id="working-with-headers">
<h2>使用头部信息（Working with Headers）<a class="headerlink" href="#working-with-headers" title="永久链接至标题">¶</a></h2>
<p>在HTTP响应返回中，响应头（Headers）是非常重要的组成部分. 它包含了一些非常有用的信息，比如HTTP状态码，响应类型等等.</p>
<p>你可以使用如下方式来设置头信息:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Setting a header by its name</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setHeader</span><span class="p">(</span><span class="s2">&quot;Content-Type&quot;</span><span class="p">,</span> <span class="s2">&quot;application/pdf&quot;</span><span class="p">);</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setHeader</span><span class="p">(</span><span class="s2">&quot;Content-Disposition&quot;</span><span class="p">,</span> <span class="s1">&#39;attachment; filename=&quot;downloaded.pdf&quot;&#39;</span><span class="p">);</span>

<span class="c1">// Setting a raw header</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setRawHeader</span><span class="p">(</span><span class="s2">&quot;HTTP/1.1 200 OK&quot;</span><span class="p">);</span>
</pre></div>
</div>
<p>A <a class="reference internal" href="../api/Phalcon_Http_Response_Headers.html"><em>Phalcon\Http\Response\Headers</em></a> bag internally manages headers. This class
retrieves the headers before sending it to client:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Get the headers bag</span>
<span class="nv">$headers</span> <span class="o">=</span> <span class="nv">$response</span><span class="o">-&gt;</span><span class="na">getHeaders</span><span class="p">();</span>

<span class="c1">// Get a header by its name</span>
<span class="nv">$contentType</span> <span class="o">=</span> <span class="nv">$headers</span><span class="o">-&gt;</span><span class="na">get</span><span class="p">(</span><span class="s2">&quot;Content-Type&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="making-redirections">
<h2>重定向（Making Redirections）<a class="headerlink" href="#making-redirections" title="永久链接至标题">¶</a></h2>
<p>可以通过 <a class="reference internal" href="../api/Phalcon_Http_Response.html"><em>Phalcon\Http\Response</em></a> 来执行HTTP重定向：</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Redirect to the default URI</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">redirect</span><span class="p">();</span>

<span class="c1">// Redirect to the local base URI</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">redirect</span><span class="p">(</span><span class="s2">&quot;posts/index&quot;</span><span class="p">);</span>

<span class="c1">// Redirect to an external URL</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">redirect</span><span class="p">(</span><span class="s2">&quot;http://en.wikipedia.org&quot;</span><span class="p">,</span> <span class="k">true</span><span class="p">);</span>

<span class="c1">// Redirect specifying the HTTP status code</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">redirect</span><span class="p">(</span><span class="s2">&quot;http://www.example.com/new-location&quot;</span><span class="p">,</span> <span class="k">true</span><span class="p">,</span> <span class="mi">301</span><span class="p">);</span>
</pre></div>
</div>
<p>All internal URIs are generated using the &#8216;url&#8217; service (by default <a class="reference internal" href="url.html"><em>Phalcon\Mvc\Url</em></a>). This example demonstrates
how you can redirect using a route you have defined in your application:</p>
<p>所有内部 URIs 都是通过 &#8216;url&#8217; 来生成的（ 默认是 <a class="reference internal" href="url.html"><em>Phalcon\Mvc\Url</em></a> ）。下面的例子演示如何通过一个应用内预先定义好的路由来重定向。</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Redirect based on a named route</span>
<span class="k">return</span> <span class="nv">$response</span><span class="o">-&gt;</span><span class="na">redirect</span><span class="p">(</span>
    <span class="p">[</span>
        <span class="s2">&quot;for&quot;</span>        <span class="o">=&gt;</span> <span class="s2">&quot;index-lang&quot;</span><span class="p">,</span>
        <span class="s2">&quot;lang&quot;</span>       <span class="o">=&gt;</span> <span class="s2">&quot;jp&quot;</span><span class="p">,</span>
        <span class="s2">&quot;controller&quot;</span> <span class="o">=&gt;</span> <span class="s2">&quot;index&quot;</span><span class="p">,</span>
    <span class="p">]</span>
<span class="p">);</span>
</pre></div>
</div>
<p>Note that a redirection doesn&#8217;t disable the view component, so if there is a view associated with the current action it
will be executed anyway. You can disable the view from a controller by executing <code class="code docutils literal"><span class="pre">$this-&gt;view-&gt;disable()</span></code>;</p>
<p>值得注意的是重定向并不禁用view组件，所以如果当前的action存在一个关联的view的话，将会继续执行它。在控制器中可以通过 <code class="code docutils literal"><span class="pre">$this-&gt;view-&gt;disable()</span></code> 来禁用view。</p>
</div>
<div class="section" id="http-http-cache">
<h2>HTTP 缓存（HTTP Cache）<a class="headerlink" href="#http-http-cache" title="永久链接至标题">¶</a></h2>
<p>One of the easiest ways to improve the performance in your applications and reduce the traffic is using HTTP Cache.
Most modern browsers support HTTP caching and is one of the reasons why many websites are currently fast.</p>
<p>HTTP Cache can be altered in the following header values sent by the application when serving a page for the first time:</p>
<ul class="simple">
<li><em>Expires:</em> With this header the application can set a date in the future or the past telling the browser when the page must expire.</li>
<li><em>Cache-Control:</em> This header allows to specify how much time a page should be considered fresh in the browser.</li>
<li><em>Last-Modified:</em> This header tells the browser which was the last time the site was updated avoiding page re-loads</li>
<li><em>ETag:</em> An etag is a unique identifier that must be created including the modification timestamp of the current page</li>
</ul>
<div class="section" id="setting-an-expiration-time">
<h3>设置过期时间（Setting an Expiration Time）<a class="headerlink" href="#setting-an-expiration-time" title="永久链接至标题">¶</a></h3>
<p>The expiration date is one of the easiest and most effective ways to cache a page in the client (browser).
Starting from the current date we add the amount of time the page will be stored
in the browser cache. Until this date expires no new content will be requested from the server:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="nv">$expiryDate</span> <span class="o">=</span> <span class="k">new</span> <span class="nx">DateTime</span><span class="p">();</span>
<span class="nv">$expiryDate</span><span class="o">-&gt;</span><span class="na">modify</span><span class="p">(</span><span class="s2">&quot;+2 months&quot;</span><span class="p">);</span>

<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setExpires</span><span class="p">(</span><span class="nv">$expiryDate</span><span class="p">);</span>
</pre></div>
</div>
<p>The Response component automatically shows the date in GMT timezone as expected in an Expires header.</p>
<p>If we set this value to a date in the past the browser will always refresh the requested page:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="nv">$expiryDate</span> <span class="o">=</span> <span class="k">new</span> <span class="nx">DateTime</span><span class="p">();</span>
<span class="nv">$expiryDate</span><span class="o">-&gt;</span><span class="na">modify</span><span class="p">(</span><span class="s2">&quot;-10 minutes&quot;</span><span class="p">);</span>

<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setExpires</span><span class="p">(</span><span class="nv">$expiryDate</span><span class="p">);</span>
</pre></div>
</div>
<p>Browsers rely on the client&#8217;s clock to assess if this date has passed or not. The client clock can be modified to
make pages expire and this may represent a limitation for this cache mechanism.</p>
</div>
<div class="section" id="cache-control">
<h3>Cache-Control<a class="headerlink" href="#cache-control" title="永久链接至标题">¶</a></h3>
<p>This header provides a safer way to cache the pages served. We simply must specify a time in seconds telling the browser
how long it must keep the page in its cache:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Starting from now, cache the page for one day</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setHeader</span><span class="p">(</span><span class="s2">&quot;Cache-Control&quot;</span><span class="p">,</span> <span class="s2">&quot;max-age=86400&quot;</span><span class="p">);</span>
</pre></div>
</div>
<p>The opposite effect (avoid page caching) is achieved in this way:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Never cache the served page</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setHeader</span><span class="p">(</span><span class="s2">&quot;Cache-Control&quot;</span><span class="p">,</span> <span class="s2">&quot;private, max-age=0, must-revalidate&quot;</span><span class="p">);</span>
</pre></div>
</div>
</div>
<div class="section" id="e-tag">
<h3>E-Tag<a class="headerlink" href="#e-tag" title="永久链接至标题">¶</a></h3>
<p>An &#8220;entity-tag&#8221; or &#8220;E-tag&#8221; is a unique identifier that helps the browser realize if the page has changed or not between two requests.
The identifier must be calculated taking into account that this must change if the previously served content has changed:</p>
<div class="highlight-php"><div class="highlight"><pre><span class="cp">&lt;?php</span>

<span class="c1">// Calculate the E-Tag based on the modification time of the latest news</span>
<span class="nv">$mostRecentDate</span> <span class="o">=</span> <span class="nx">News</span><span class="o">::</span><span class="na">maximum</span><span class="p">(</span>
    <span class="p">[</span>
        <span class="s2">&quot;column&quot;</span> <span class="o">=&gt;</span> <span class="s2">&quot;created_at&quot;</span>
    <span class="p">]</span>
<span class="p">);</span>

<span class="nv">$eTag</span> <span class="o">=</span> <span class="nb">md5</span><span class="p">(</span><span class="nv">$mostRecentDate</span><span class="p">);</span>

<span class="c1">// Send an E-Tag header</span>
<span class="nv">$response</span><span class="o">-&gt;</span><span class="na">setHeader</span><span class="p">(</span><span class="s2">&quot;E-Tag&quot;</span><span class="p">,</span> <span class="nv">$eTag</span><span class="p">);</span>
</pre></div>
</div>
</div>
</div>
</div>


                    </div>
                  </div>
                </div>
            </div>
          </td>
        </tr>
      </table>
    <div class="related">
      <ul>
        <li class="right" >
          <a href="../genindex.html" title="总目录"
             >索引</a></li>
        <li class="right" >
          <a href="cookies.html" title="Cookie 管理（Cookies Management）"
             >下一页</a> |</li>
        <li class="right" >
          <a href="request.html" title="Request Environment"
             >上一页</a> |</li> 
      </ul>
    </div>

      <div class="prefooter">
  <div class="container">
      <div class="row">
          <div class="col-sm-3 text-right">
              <span>Follow along:</span>
          </div>
          <div class="col-sm-6 text-center">
              <a href="https://twitter.com/phalconphp" alt="Twitter" class="btn-social btn-social-twitter"><i class="icon-twitter"></i></a>
              <a href="https://www.facebook.com/pages/Phalcon-Framework/134230726685897" alt="Facebook" class="btn-social btn-social-facebook"><i class="icon-facebook"></i></a>
              <a href="https://plus.google.com/102376109340560896457" alt="Google+" class="btn-social btn-social-googleplus"><i class="icon-googleplus"></i></a>
              <a href="https://github.com/phalcon/cphalcon" alt="Github" class="btn-social btn-social-github"><i class="icon-github"></i></a>
          </div>
          <div class="col-sm-3">
          </div>
      </div>
  </div>

</div>
<footer class="footer">
    <div class="container">
        <div class="row">
            <div class="col-xs-4 col-sm-3">
                <h4>Download</h4>
                <ul>
                    <li><a href="/download">Installing Phalcon PHP</a></li>
                    <li><a href="http://docs.phalconphp.com/en/latest/index.html" class="header-nav-link" target="_blank">Documentation</a></li>
                    <li><a href="http://api.phalconphp.com">API</a></li>
                    <li><a href="http://docs.phalconphp.com/en/latest/reference/tutorial.html">Tutorial</a></li>
                    <li><a href="http://docs.phalconphp.com/en/latest/reference/tutorial.html#sample-applications">Sample Applications</a></li>
                </ul>
            </div>
            <div class="col-xs-4 col-sm-3">
                <h4>Community</h4>
                <ul>
                    <li><a href="http://forum.phalconphp.com/" class="header-nav-link" target="_blank">Forum</a></li>
                    <li><a href="https://github.com/phalcon/cphalcon">GitHub</a></li>
                    <li><a href="https://github.com/phalcon/cphalcon/issues">Issue Tracker</a></li>
                    <li><a href="http://stackoverflow.com/questions/tagged/phalcon">Stack Overflow</a></li>
                    <li><a href="/en/testimonials">Testimonials</a></li>
                    <li><a href="http://builtwith.phalconphp.com/">Built with Phalcon</a></li>
                    <li><a href="http://store.phalconphp.com/">Store</a></li>
                </ul>
            </div>
            <div class="col-xs-4 col-sm-2">
                <h4>About</h4>
                <ul>
                    <li><a class="link-black" href="http://blog.phalconphp.com/">Blog</a></li>
                    <li><a href="/en/about">About</a></li>
                    <li><a href="/en/team">Team</a></li>
                    <li><a href="/en/roadmap">Roadmap</a></li>
                    <li><a href="/en/donate">Donate</a></li>
                    <li><a href="/en/consulting">Consulting</a></li>
                    <li><a href="/en/hosting">Hosting</a></li>
                </ul>
            </div>
            <div id="license-spaccer" class="visible-xs"></div>
            <div id="license-wrapper" class="col-xs-12 col-sm-4">
                <p class="license">
                    Phalcon is an open-source PHP framework <br>built as a C-extension. It is available under the <br>
                    <a href="http://opensource.org/licenses/BSD-3-Clause" target="_blank">new BSD License</a>.
                    <br>
                    <br>
                    Except where otherwise noted, content on this site is licensed under the
                    <a href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 License.</a>
                </p>
            </div>
        </div>
    </div>
</footer>

    </div>
    <script type="text/javascript">
    $(window).on("load", function(){
      var cx = '009733439235723428699:lh9ltjgvdz8';
      var gcse = document.createElement('script');
      gcse.type = 'text/javascript';
      gcse.async = true;
      gcse.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//www.google.com/cse/cse.js?cx=' + cx;
      var s = document.getElementsByTagName('script')[0];
      s.parentNode.insertBefore(gcse, s);
    });
    </script>

  </body>
</html>